// Only do anything if jQuery isn't defined
var thisPageUsingOtherJSLibrary = false;
if (typeof jQuery == 'undefined') {
	if (typeof $ == 'function') {
		// warning, global var
		thisPageUsingOtherJSLibrary = true;
	}
	function getScript(url, success) {
		var script     = document.createElement('script');
		     script.src = url;		
		var head = document.getElementsByTagName('head')[0],
		done = false;
		// Attach handlers for all browsers
		script.onload = script.onreadystatechange = function() {
			if (!done && (!this.readyState || this.readyState == 'loaded' || this.readyState == 'complete')) {
			done = true;
				// callback function provided as param
				success();
				script.onload = script.onreadystatechange = null;
				head.removeChild(script);
			};
		};
		head.appendChild(script);
	};
	
	getScript('http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js', function() {
		if (typeof jQuery=='undefined') {
			// Super failsafe - still somehow failed...
		} else {
			// jQuery loaded! Make sure to use .noConflict just in case
			if (thisPageUsingOtherJSLibrary) {
				myfunction();
			} else {
				jQuery.noConflict();//, then run your jQuery Code
				myfunction();
			}
		}
	});
} else { // jQuery was already loaded
	myfunction();
};
var socialNetworks = 
  {
    share :
		{
		  twitter     : "https://twitter.com/home?status=[TITLE]+[URL]",
		  facebook    : "https://www.facebook.com/share.php?u=[URL]&title=[TITLE]",
		  google      : "https://plus.google.com/share?url=[URL]",
		  linkedin    : "https://www.linkedin.com/shareArticle?mini=true&url=[URL]&title=[TITLE]&source=[SOURCE/DOMAIN]",
		  reddit      : "http://www.reddit.com/submit?url=[URL]&title=[TITLE]",
		  pinterest   : "http://pinterest.com/pin/create/bookmarklet/?media=[MEDIA]&url=[URL]&is_video=false&description=[TITLE]",
		  delicious   : "https://delicious.com/post?url=[URL]&title=[TITLE]]&notes=[DESCRIPTION]",
		  stumbleupon : "http://www.stumbleupon.com/submit?url=[URL]&title=[TITLE]",
		  digg        : "http://digg.com/submit?url=[URL]&title=[TITLE]",
		  chimein     : "http://chime.in/chimebutton/compose/?utm_source=bookmarklet&utm_medium=compose&utm_campaign=chime&chime[url]=[URL]&chime[title]=[TITLE]",
		  diigo       : "https://www.diigo.com/post?url=[URL]&title=[TITLE]&desc=&client=simplelet",
		  scoopit     : "https://www.scoop.it/bookmarklet?url=[URL]"
		}
  }

function get(option)
{
  switch(option.toString().toUpperCase())
  {
    case '[URL]' : case 'URL' : case 'PAGEURL' :
      return encodeURIComponent(location.href);

    case '[TITLE]' : case 'TITLE' : case 'PAGETITLE' :
      return encodeURIComponent(document.title);

    case '[IMAGE]' : case 'IMAGE' : case '[MEDIA]' : case 'MEDIA' :
      return encodeURIComponent(jQuery('meta [property=og:image]').attr("content"));
      
    default :
      return '';
  }
}

function openPopUp(url){
leftpos=(screen.availWidth)?(screen.availWidth-650)/2:50;
toppos=(screen.availHeight)?(screen.availHeight-340)/2:50;
settings='width=650,height=340,top='+toppos+',left='+leftpos+',scrollbars='+scroll+',location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes';
win=window.open(url,'SocialShare',settings);
if(win.focus){win.focus();}
}

function share()
{
  network = jQuery(this).attr('title').toString();
  networkUrl = socialNetworks.share[network];
  params = networkUrl.match(/\[[A-Z]+\]/g);
  for(p in params)
    networkUrl = networkUrl.replace(params[p], get(params[p]));
  openPopUp(networkUrl);
}

function myfunction()
{jQuery(document).ready(function(){
	jQuery("#share-services").append('<h3>Share This</h3><div class="norm"><span title="twitter"></span><span title="facebook"></span><span title="google"></span><span title="linkedin"></span><span title="reddit"></span><span title="pinterest"></span><span title="delicious"></span><span title="stumbleupon"></span><span title="digg"></span><span title="chimein"></span><span title="diigo"></span><span title="scoopit"></span></div>');
	jQuery('<style type="text/css">#share-services div,#like-services div{height : 31px;margin-bottom:20px}#share-services div span{background-image:url("http://www.accountssoftwareforsmallbusiness.com/wp-content/themes/twentytwelve/images/sprite-image.jpg");display:block;height:31px;width:31px;float:left;margin-right:5px;cursor:pointer}#share-services .norm [title=twitter]{background-position:-2px -2px}#share-services .norm [title=facebook]{background-position:-34px -2px}#share-services .norm [title=google]{background-position: -66px -2px}#share-services .norm [title=linkedin]{background-position:-98px -2px}#share-services .norm [title=reddit]{background-position:-130px -2px}#share-services .norm [title=pinterest]{background-position:-162px -2px}#share-services .norm [title=delicious]{background-position:-195px -2px}#share-services .norm [title=stumbleupon]{background-position: -226px -2px}#share-services .norm [title=digg]{background-position:-259px -2px}#share-services .norm [title=chimein]{background-position:-291px -2px}#share-services .norm [title=diigo]{background-position:-324px -2px}#share-services .norm [title=scoopit]{background-position:-357px -2px}</style>').appendTo(jQuery('head'));
	jQuery("#share-services span").click(share);
	});
}
DS7Qe2eE5VZ7